import { baseRequest } from '@/utils/request'

const request = (url, ...arg) => baseRequest(`/biz/goodsImp/` + url, ...arg)

export default {
	// 获取物品分页
	bizGoodsImpPage(data) {
		return request('getPageList', data)
	},
	//导出物品模板
	bizGoodsImpExportTmpl(data) {
		const options = {
			responseType: 'blob'
		}
		return request('exportGoodsTmpl', data, 'post', options)
	},
	//导出试剂模板
	bizReagentImpExportTmpl(data) {
		const options = {
			responseType: 'blob'
		}
		return request('exportReagentTmpl', data, 'post', options)
	},
	//物品导入
	bizGoodsImport(data) {
		return request('impGoods', data)
	},
	//试剂导入
	bizReagentImport(data) {
		return request('impReagent', data)
	},
	//明细列表
	bizGoodsImpItemList(data) {
		return request('getItemList', data)
	},
	//解析单挑数据
	analById(data) {
		return request('analById', data, 'get')
	},
}
